package com.zyl.longpicturebackend.exception;


public enum ErrorCode {

    OK(0, "OK"),
    PARAMS_ERROR(40000, "请求参数错误"),
    NOT_LOGING_ERROR(40100, "未登录"),
    NOT_AUTHORIZATION_ERROR(40101, "无权限"),
    FORBIDDEN_ERROR(403, "禁止访问"),
    NOT_FOUND_ERROR(40400, "请求数据不存在"),
    SYSTEM_ERROR(50000, "系统内部错误"),
    OPERATION_ERROR(50001, "操作失败");

    private int code;

    private String message;

    ErrorCode(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public String getMessage() {
        return message;
    }

    public int getCode() {
        return code;
    }


}
